/*
 *@Description: 短信模型
 *@Author: panlua
 *@Date: 2019-05-23 17:28:16
*/

const mongoose = require('mongoose')
const Schema = mongoose.Schema

const smsSchema = new Schema({
  mobileNumber: {
    type: Number,
    required: true
  },
  code: {
    type: Number,
    required: true
  },
  createTime: { // 获取时间
    type: Number,
    required: true
  },
  expiresTime: { // 过期时间
    type: Number,
    required: true
  }
})

module.exports = mongoose.model('Sms', smsSchema, 'sms')